Security Device PDT Globals (Dongle/Ibutton Stuff)
Clay Greene
2011_10_11


The CPPM Card uses a USB interface to talk to the dongle.

The main SL1 interpreted Operating System is located in one main file called mainos.sys.
MainOS.Sys is stored at this location on the installation Compact Flash
CF2\swload\0600_RMR.N40\target\p\load\mainos.sys

The Dongle on the system used when entering these PDT commands was the following:

NT Corporate ID               :  18110000
NT SDID                       :  10390134
SDID                          :  AB5E700C969FC989
Security Device Type          :  NT_STD
System Serial Number          :  318826319



1.  The Family Code below is made up of the NT_CORP ID (see #2 below) and the main family code for the DS-1982 which is '89'.
The default family code for the DS1982 is '09' so Nortel may be having Maxim provide them with special units encode with '89'.
The family code will appear as the last 2 digits of the unique 64 byte ID number that is lasered into the DS1982 at the factory.
This cannot be changed via EPROM programming.

pdt> lkup DS1982
DS1982U_FAMILY_CODE       0x02a0a2c0 data     (mainos.sym) (local)

pdt> DS1982U_FAMILY_CODE
DS1982U_FAMILY_CODE 0x2a0a2c0 data     (local) : value = 1120393 = 0x00111889
pdt>

-----------------------------------------------------------------------------------------------

2.  The following CORP Codes (TCH/DST/STD) are the Byte1 and Byte2 in the DS1982 Main Memory Page.
This value can be changed via EPROM programming.


pdt> lkup NT_CORP
NT_CORP_TCH_ID            0x02a0a2c5 data     (mainos.sym) (local)
NT_CORP_DST_ID            0x02a0a2c9 data     (mainos.sym) (local)
NT_CORP_STD_ID            0x02a0a2c1 data     (mainos.sym) (local)
pdt>

pdt> NT_CORP_TCH_ID
NT_CORP_TCH_ID  0x2a0a2c5 data     (local) : value = 4377 = 0x00001119

pdt> NT_CORP_DST_ID
NT_CORP_DST_ID  0x2a0a2c9 data     (local) : value = 4378 = 0x0000111A

pdt> NT_CORP_STD_ID
NT_CORP_STD_ID  0x2a0a2c1 data     (local) : value = 4376 = 0x00001118
pdt>

-----------------------------------------------------------------------------------------------

3.  Not sure if this is something good yet.

pdt> lkup SYSLOAD1$SECURITY_OK      0x01c08b50 text     (mainos.sym) (local)

pdt> SYSLOAD1$SECURITY_OK
value = 1 = 0x1

-----------------------------------------------------------------------------------------------

4.   Dongle (Hit the Jackpot)

If type is:
data:	This global points to data (ie a variable)
text:	This global points to a function/subroutine
bss:	This global points to data.  BSS in many compilers usually refers to Static Variables.

pdt> lkup dongle					   Clays Notes (Var/function)
dongleChkDebug            0x02a04e10 data     (mainos.sym) Var
dongleClose               0x00348c30 text     (mainos.sym) function
_GLOBAL_$F$dongleChkDebug 0x02a04e20 data     (mainos.sym) var
dongleId                  0x00348890 text     (mainos.sym) function
kcm_dongle_from_file      0x0120b7d0 text     (mainos.sym) function
dongleReset               0x00348d00 text     (mainos.sym) function
dongleInfo                0x01206d10 text     (mainos.sym) function
dongleChkIsActive         0x011d9df0 text     (mainos.sym) function
dongleChkActive           0x02a04e1c data     (mainos.sym) var
_GLOBAL_$F$dongleInfo     0x02a13600 data     (mainos.sym) var
dongleCheck               0x011d9c70 text     (mainos.sym) function
dongleError               0x02e40a1c bss      (mainos.sym) var
dongleSemId               0x02a1544c data     (mainos.sym) var
_GLOBAL_$F$dongleSemId    0x02a15450 data     (mainos.sym) var
dongleRam                 0x00348a50 text     (mainos.sym) function
dongleInit                0x00348770 text     (mainos.sym) function
donglePresence            0x003486f0 text     (mainos.sym) function
pdt>

pdt> lkup Dongle
sutlGetDongleIntStatus    0x00fdae50 text     (mainos.sym) function
siopGetDongleEnlStatus    0x00fc0ca0 text     (mainos.sym) function
_GLOBAL_$F$cppmDongleDebug 0x029809ec data     (mainos.sym) var
ipmgDongleCheck           0x01830760 text     (mainos.sym) function
sutlGetDongleEnlStatus    0x00fca4a0 text     (mainos.sym) function
ioduGetDongleStatus       0x0120d540 text     (mainos.sym) function
convertDongleId           0x01830d50 text     (mainos.sym) function
getDongleError            0x01206e90 text     (mainos.sym) function
siopDislDongle            0x00fc0c90 text     (mainos.sym) function
sutlDislDongle            0x00fc9a60 text     (mainos.sym) function
siopEnlDongle             0x00fc0c80 text     (mainos.sym) function
_GLOBAL_$F$siopEnlDongle  0x029c4980 data     (mainos.sym) var
sutlEnlDongle             0x00fc9940 text     (mainos.sym) function
siop2691DongleTest        0x00f627e0 text     (mainos.sym) (local) var
cppmDongleDebug           0x029808c4 data     (mainos.sym)
pdt>

pdt> dongleChkDebug
dongleChkDebug  0x2a04e10 data     : value = 0 = 0x00000000

pdt> dongleClose
value = 0 = 0x0
pdt>

pdt> _GLOBAL_$F$dongleChkDebug
_GLOBAL_$F$dongleChkDebug 0x2a04e20 data     : value = 16 = 0x00000010
pdt>

pdt> dongleId
0x209e7520 (pdtShell01): Dongle driver maybe not initialized.
value = 7 = 0x7
pdt>

pdt> dongleInit
pdt> dongleId dongleSemId
value = 0 = 0x0
pdt>  We at least get a return code of 0 now.  But where's the ID??


pdt> kcm_dongle_from_file
value = -1 = 0xFFFFFFFF
pdt>


pdt> dongleInfo
0x209e7520 (pdtShell01): Error : Calling dongleId() with NULL pointer.

SRPT4624: Security Device on Core is invalid
          Check and reseat security device
value = 7 = 0x7
pdt>


pdt> dongleInfo 0
This caused the system to lockup PDT.  I had to Init to get it back.



pdt> dongleInfo 1


PDT login on /tyCo/0
Username:
BERR705 EXC 0: Exception 14 in Task "pdtShell01" (0x209e7520)
       SR=0x10202, PC=0x348953, Addr(CR2)=0x8, ErrCode=0x2,ValidFlags=0xb

SRPT786 RST 0: Task pdtShell01 being restarted


pdt> dongleInfo dongleSemId
value = 0 = 0x0
pdt>This seems to work...passing the dongleSemId to the routine.  The return code is 0x0 at least.  Now where is it putting the actual dongle Info that it retrieves??



pdt> dongleChkIsActive
value = 0 = 0x0
pdt>

pdt> dongleChkActive
dongleChkActive 0x2a04e1c data     : value = 0 = 0x00000000
pdt>

pdt> _GLOBAL_$F$dongleInfo
_GLOBAL_$F$dongleInfo 0x2a13600 data     : value = 16 = 0x00000010
pdt>

pdt> dongleCheck
PDT locks up after this command.  Had to INIT to get it back.

pdt> dongleError
dongleError     0x2e40a1c bss      : value = 0 = 0x00000000
pdt>

pdt> dongleSemId
dongleSemId     0x2a1544c data     : value = 88931768 = 0x054CFDB8
pdt>

pdt> _GLOBAL_$F$dongleSemId
_GLOBAL_$F$dongleSemId 0x2a15450 data     : value = 16 = 0x00000010
pdt>

pdt> dongleRam
0x209db228 (pdtShell01): Dongle driver maybe not initialized.
value = 7 = 0x7
pdt>

pdt> donglePresence
0x209db228 (pdtShell01): Dongle driver maybe not initialized.
value = 7 = 0x7
pdt>

pdt> dongleInit
value = 0 = 0x0
The dongleInit routine needs to be called before calling some of the other dongle functions.

------------------------------------------------------------------


dongle functions (subroutines)

dongleClose               0x00348c30 text     (mainos.sym) function
dongleId                  0x00348890 text     (mainos.sym) function
kcm_dongle_from_file      0x0120b7d0 text     (mainos.sym) function
dongleReset               0x00348d00 text     (mainos.sym) function
dongleInfo                0x01206d10 text     (mainos.sym) function
dongleChkIsActive         0x011d9df0 text     (mainos.sym) function
dongleCheck               0x011d9c70 text     (mainos.sym) function
dongleRam                 0x00348a50 text     (mainos.sym) function
dongleInit                0x00348770 text     (mainos.sym) function
donglePresence            0x003486f0 text     (mainos.sym) function


dongle variables (data)

dongleChkDebug            0x02a04e10 data     (mainos.sym) Var
_GLOBAL_$F$dongleChkDebug 0x02a04e20 data     (mainos.sym) var
dongleChkActive           0x02a04e1c data     (mainos.sym) var
_GLOBAL_$F$dongleInfo     0x02a13600 data     (mainos.sym) var
dongleError               0x02e40a1c bss      (mainos.sym) var
dongleSemId               0x02a1544c data     (mainos.sym) var
_GLOBAL_$F$dongleSemId    0x02a15450 data     (mainos.sym) var